package com.zf.yichat.model;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import javax.persistence.*;

@Table(name = "member_level")
public class MemberLevel implements Serializable {
    @Id
    private Long id;

    /**
     * 等级名称
     */
    private String name;

    /**
     * 等级类型
     */
    private String type;

    /**
     * 金额
     */
    private BigDecimal money;

    /**
     * 0 正常 1冻结
     */
    private Integer status;

    @Column(name = "create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    private static final long serialVersionUID = 1L;

    public MemberLevel(Long id, String name,String type, BigDecimal money, Integer status, Date createTime) {
        this.id = id;
        this.name = name;
        this.type = type;
        this.money = money;
        this.status = status;
        this.createTime = createTime;
    }

    public MemberLevel() {
        super();
    }

    /**
     * @return id
     */
    public Long getId() {
        return id;
    }

    /**
     * @param id
     */
    public void setId(Long id) {
        this.id = id;
    }

    /**
     * 获取等级名称
     *
     * @return name - 等级名称
     */
    public String getName() {
        return name;
    }

    /**
     * 设置等级名称
     *
     * @param name 等级名称
     */
    public void setName(String name) {
        this.name = name == null ? null : name.trim();
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    /**
     * 获取金额
     *
     * @return money - 金额
     */
    public BigDecimal getMoney() {
        return money;
    }

    /**
     * 设置金额
     *
     * @param money 金额
     */
    public void setMoney(BigDecimal money) {
        this.money = money;
    }

    /**
     * 获取0 正常 1冻结
     *
     * @return status - 0 正常 1冻结
     */
    public Integer getStatus() {
        return status;
    }

    /**
     * 设置0 正常 1冻结
     *
     * @param status 0 正常 1冻结
     */
    public void setStatus(Integer status) {
        this.status = status;
    }

    /**
     * @return create_time
     */
    public Date getCreateTime() {
        return createTime;
    }

    /**
     * @param createTime
     */
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}